package main

import (
	"fmt"
	"time"
)

func main() {
	var arr = make([]int, 10)
	for i := 0; i < 10; i++ {
		go func(i int) {
			arr[i] = arr[i] + i + 1
		}(i)
	}
	time.Sleep(time.Nanosecond)
	fmt.Println(arr)
}
